<?php
	require_once("actions/EquipeAction.php");
	$action = new EquipeAction();
	$action->execute();
	include("header.php");
?>

<script type="text/javascript">
	$(document).ready(function(){
	    $("#employe").accordion({autoheight: false});
	  });
  </script>
	
	
	<div id='employe'>
	 
	<?php
		$resultat=$action->lireEquipe();
		if (count($resultat)>0)
			foreach($resultat as $ligne){
				$nom = "".$action->lireNode("equipe","nom");
				$prenom = "".$action->lireNode("equipe","prenom");
				$description = "".$action->lireNode("equipe","description");
				$poste = "".$action->lireNode("equipe","poste");
				$url="".$action->lireNode("equipe","url");
	?>			
		
			<h3><a href="#"><?php echo($ligne[$prenom]." ".$ligne[$nom]) ?></a></h3>			
			<!--div vide essentiel a cause du jQuery. ask the guy who made it -->
			
			<div>
				<div id='detailEmploye'>
				<img src="<?php echo($ligne[$url])?>" alt="<?php echo($ligne[$prenom]." ".$ligne[$nom])?>"/>
					<div id='poste'><?php echo($ligne[$poste]) ?></div>
					<div id='description'><?php echo($ligne[$description]) ?></div>
					
					<div id="clear"></div>
				</div>
			</div>
	<?php
		}
	?>
	</div>


	
  
<?php 
	include("footer.php");
?>